package com.dubious.interview.euler.booleans;

/**
 * Allows to track true/false flags for a large number of objects.  
 * Arrays and BitSet normally only support up to Integer.MAX_VALUE objects.
 * Implementations of this should, in theory, should support up to 
 * Long.MAX_VALUE = Integer.MAX_VALUE ^ 2 objects.
 */
public interface Booleans
{
    /**
     * Set a flag.
     * @param index The index of the element to flag.
     * @param value The value of the flag.
     */
    void set(long index, boolean value);
    
    /**
     * Get the value of a flag.
     * @param index The index of the flag.
     * @return The value of the flag.
     */
    boolean get(long index);
}